Expression Trees in .NET 4.0: Expression.Call fails to find method “get_Item” in type List

The overload you use is for static methods only (see documentation: msdn.microsoft.com/en-us/library/bb35110... ). And "get_Item" is clearly not a static method. So, you need to use a different method overload.

Try this, for example: return Expression. Call(callExpression. Object, callExpression.

Method, callExpression.Arguments.ToArray()).

The overload you use is for static methods only (see documentation: msdn.microsoft.com/en-us/library/bb35110...). And "get_Item" is clearly not a static method. So, you need to use a different method overload.

Try this, for example: return Expression. Call(callExpression. Object, callExpression.

Method, callExpression.Arguments.ToArray()).

It's official: I'm going to add the "beginner" tag to my questions from now on. +1 (and many thanks) for bothering to answer this "duh! " stuff (should've read the docs more carefully before posting to begin with).

– d.. Jan 19 '10 at 1:42 If you ask questions about expression trees, you are definitely not a beginner :-) It is a quite advanced topic. – Alexandra Rusina Jan 19 '10 at 3:43 @Sasha He could be a beginner in Expression Trees ) pleased to see girls on this forum, from Microsoft, and Russians! Wah.

– serhio Sep 9 at 17:24.

Body); // Prints out "u. MethodCallExpression copyGetComponent = CopyCallExpression(component. FullName == callExpression.Method.DeclaringType.

FullName); // True! Type argTypes = (from argument in callExpression. Arguments select argument.

// Next line throws an exception: No method 'get_Item' exists on type 'System.Collections.Generic. // How does this come together with items (1) and (2) above? WriteLine(invokeProp); // you => u.

Body); // u. Expression copyGetComponent = CopyCallExpression(invokeProp. LambdaExpression copyInvokeProp = Expression.

WriteLine(copyInvokeProp); // you => u. Body); // u. MethodInfo info = callExpression.

PropertyInfo propInfo = typeof(List). Object, propInfo, callExpression. Type argTypes = (from argument in callExpression.

Arguments select argument.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.